package com.code.day18;

import java.util.LinkedList;

public class Demo02Pop_Push {
    public static void main(String[] args) {
        LinkedList<String> list = new LinkedList<>();
        list.push("张三");
        list.push("李四");
        list.push("王五");
        list.push("赵六");
        list.push("田七");
        System.out.println(list.pop());
        System.out.println(list.pop());
        System.out.println(list.pop());
        System.out.println(list.pop());
        System.out.println(list.pop());
        list.push("超级刘大胆");
        System.out.println(list);
    }
}
